﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using MSAcademic.v2.Infrastructure.Article;

namespace MSAcademic.v2.Web.Areas.Admin.Models.Picture
{
    public partial class UploadFrontPicturesViewModel
    {
        public int ArticleId { get; set; }

        public double NormalFrontPictureX1 { get; set; }
        public double NormalFrontPictureY1 { get; set; }
        public double NormalFrontPictureX2 { get; set; }
        public double NormalFrontPictureY2 { get; set; }

        public double BigFrontPictureX1 { get; set; }
        public double BigFrontPictureY1 { get; set; }
        public double BigFrontPictureX2 { get; set; }
        public double BigFrontPictureY2 { get; set; }
    }
    public partial class UploadFrontPicturesViewModel
    {
        public IArticle Article
        {
            get
            {
                if (_Article == null)
                {
                    _Article = new Lazy<IArticle>(() => _articleQueries.GetArticle(this.ArticleId));
                }
                return _Article.Value;
            }
        }
        private Lazy<IArticle> _Article;
    }
    public partial class UploadFrontPicturesViewModel
    {
        public IArticleQueries _articleQueries { get; set; }
        public UploadFrontPicturesViewModel(IArticleQueries articleQueries)
        {
            _articleQueries = articleQueries;
        }
    }
}